package com.cherrypt.api.core.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.cherrypt.api.model.dataobject.Notice;

import java.util.List;

public interface NoticeService extends IService<Notice> {

    /**
     * 获取Redis中的Notice
     *
     * @return
     */
    List<Notice> getRedisNotice();

    /**
     * 存储Notice
     */
    void saveRedisNotice(List<Notice> notice);

    /**
     * 获取最新的size条公告
     *
     * @param size
     * @return
     */
    List<Notice> getNowNotice(int size);
}
